<?php
declare (strict_types=1);
/**
 * Created by .
 * User: luogan
 * Date: 2021/12/30
 */

namespace App\Service;


use App\Exception\ErrorException;
use App\Model\AdminLoginLog;

class AdminLoginLogService
{
    public function list($data)
    {
        $result = AdminLoginLog::query()->get();
        if (!$result){
            throw new ErrorException();
        }
        return $result;
    }


    public function detail($id)
    {
        $result = AdminLoginLog::query()->find($id);
        if (!$result){
            throw new ErrorException();
        }
        return $result;
    }


}
